﻿using Abp.Domain.Repositories;
using ARchGL.Platform.Electrocar.Application.Dto;
using ARchGL.Platform.Electrocar.Application.Utils;
using ARchGL.Platform.Electrocar.Core;
using ARchGL.Platform.EntityFrameworkCore;
using AutoMapper;
using System;
using System.Collections.Generic;
using System.Text;

namespace ARchGL.Platform.Tests.TestDatas
{
    /// <summary>
    /// Electrocar文件Files测试预置数据
    /// </summary>
    public class TestElectrocarFilesBuilder
    {
        private readonly IRepository<Files, Guid> _filesRepository;

        public TestElectrocarFilesBuilder()
        {

        }
        public void Create()
        {
            CreateFiles();
            ExportToExcel();
        }

        public void CreateFiles()
        {
            var TestFile = new Files
            {
                Id = Guid.Parse("00000000-0000-0000-0000-000000000000"),
                FileDirectoryId = Guid.Parse("00000000-0000-0000-0000-000000000000"),
                FileId = Guid.Parse("00000000-0000-0000-0000-000000000000"),
                Name = "测试文件一",
                Url = "测试文件url",
                Extension = "txt",
                Size = 1,
                CreatorUserName = "test"
            };

            _filesRepository.Insert(TestFile);
        }
        public void ExportToExcel()
        {
            List<string[]> strList = new List<string[]>
            {
                new string[]{"TestId", "00000000-0000-0000-0000-000000000000"},
                new string[]{"ModelId", "00000000-0000-0000-0000-000000000000" },
                new string[]{"AccountId", "4d68853f-2456-4e64-9397-0bf33392c837" }
            };
            //new ExcelHelper().ExportExcel("ElectrocarIds", strList);
        }
    }
}
